package com.ssm.demo.service.impl.typebook;

import java.util.List;

import javax.annotation.PostConstruct;
import javax.transaction.Transactional;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.ssm.demo.dao.typebook.ITypeBookDao;
import com.ssm.demo.model.TypeBook;
import com.ssm.demo.service.impl.BaseServiceImpl;
import com.ssm.demo.service.typebook.ITypeBookService;
/**
 * 
* @ClassName: TypeBookServiceImpl  
* @Description: TypeBookService 实现
* @author jing Lei  
* @date 2018年12月20日  
*
 */
@Service
@Transactional
public class TypeBookServiceImpl extends BaseServiceImpl<TypeBook> implements ITypeBookService {
    @Autowired
	private ITypeBookDao itypeBookDao;
    /**
     * 注入基础方法
     */
    @PostConstruct
    private void postConstruct(){
		baseIdo = itypeBookDao;
	}
    
    /**
     * 
    * <p>Title: findByTypeName</p>  
    * <p>Description: 通过name查询</p>  
    * @param name  名字
    * @return  名字
    * @see com.ssm.demo.service.typebook.ITypeBookService#findByTypeName(java.lang.String)
     */
	@Override
	public List<TypeBook> findByTypeName(String typeName) {
		
		List<TypeBook> list = itypeBookDao.findByName(typeName);
		return list;
	}

	/**
	* <p>Title: query</p>  
	* <p>Description: </p>  
	* @param queryName
	* @param queryValue
	* @return  
	* @see com.ssm.demo.service.typebook.ITypeBookService#query(java.lang.String, java.lang.String)  
	*/  
	
	@Override
	public List<TypeBook> query(String queryName, String queryValue) {
		return itypeBookDao.query(queryName, queryValue);
	}

}
